<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>更新英雄技能</title>
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.9.3/css/bulma.min.css">
</head>
<body>
<div class="section">
    <div class="container">
        <h2 class="title has-text-centered">更新英雄技能</h2>
        <form th:action="@{/skills/update/{id}(id=${updateSkills.skillId})}" method="post" class="box">
            <input type="hidden" name="skillId" th:value="${updateSkills.skillId}"/>

            <div class="field">
                <label class="label" for="skillId">技能ID:</label>
                <div class="control">
                    <input class="input" type="text" id="skillId" name="skillId" th:value="${updateSkills.skillId}" required disabled>
                </div>
            </div>

            <div class="field">
                <label class="label" for="heroID">英雄ID:</label>
                <div class="control">
                    <input class="input" type="text" id="heroID" name="heroID" th:value="${updateSkills.heroId}" required>
                </div>
            </div>
            <div class="field">
                <label for="skillName">技能名称:</label>
                <input type="text" id="skillName" name="skillName" th:value="${updateSkills.skillName}" required>
            </div>
            <div class="field">
                <label for="skillDescription">技能描述:</label>
                <input type="text" id="skillDescription" name="skillDescription" th:value="${updateSkills.skillDescription}" required>
            </div>
            <div class="field">
                <label for="skillType">技能类型:</label>
                <input type="text" id="skillType" name="skillType" th:value="${updateSkills.skillType}" required>
            </div>
            <div class="field">
                <label for="skillCooldown">技能冷却时间:</label>
                <input type="number" id="skillCooldown" name="skillCooldown" min="1" th:value="${updateSkills.skillCooldown}" required>
            </div>
            <div class="field">
                <label for="skillRange">技能范围:</label>
                <input type="text" id="skillRange" name="skillRange" th:value="${updateSkills.skillRange}" required>
            </div>
            <div class="field">
                <label for="skillDamage">技能伤害:</label>
                <input type="text" id="skillDamage" name="skillDamage" th:value="${updateSkills.skillDamage}" required>
            </div>
            <div class="field">
                <label for="skillEffects">技能效果:</label>
                <input type="text" id="skillEffects" name="skillEffects" th:value="${updateSkills.skillEffects}" required>
            </div>
            <div class="field is-grouped is-grouped-right">
                <div class="control">
                    <button class="button is-primary" type="submit">更新</button>
                </div>
            </div>

            <p th:if="${message != null}" class="notification is-primary" th:text="${message}"></p>
        </form>
    </div>
</div>
</body>
</html>